<template>
    <div>
      
        <van-tabbar  v-model="active" >
            <van-tabbar-item icon="home-o" to="/" >首页</van-tabbar-item>
            <van-tabbar-item icon="label-o" to="/zhuanti" >专题</van-tabbar-item>
            <van-tabbar-item icon="apps-o" to='/fenlei/1005000'>分类</van-tabbar-item>

            <van-tabbar-item icon="shopping-cart-o" to="/cart" @click="gowu">购物车</van-tabbar-item>
            <van-tabbar-item icon="user-o" to="/user" >我的</van-tabbar-item>
          </van-tabbar>
    
            
            
    </div>
</template>

<script>
// import {Toast} from 'vant'
export default {
    
    data() {
        return {
          active:''
        };
    },
    created(){
   
    },

    mounted() {
        
    },

    methods: {
        //    fun1(){
          
        //    this.active = 0
        //   },
        //   fun2(){
        //     this.active = 1

        //   },
        //   fun3(){
        //     this.active = 2

            
        //   }
        gowu(){
            let token=localStorage.getItem('token')
            if(!token){
                this.active=4
            }
        }
    },
};
</script>

<style lang="scss" scoped>

</style>